package com.java46.service;

import com.java46.entity.ServiceLarge;
import com.java46.entity.Vehicle;
import com.java46.mapper.ServiceLargeMapper;
import com.java46.mapper.VehicleMapper;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import java.util.List;

/**
 * 进入网页前操作
 */
@Service
@Transactional
public class IndexService {
    @Autowired
    private ServiceLargeMapper serviceLargeMapper;
    @Autowired
    private VehicleMapper vehicleMapper;
    /*
     * 查询全部服务类型
     *
     * @author Tigger Wu
     * @date 2018/8/16 13:13
     * @param
     * @return
     */

    public List<ServiceLarge> queryService(){
        List<ServiceLarge>slist = serviceLargeMapper.selectAll();
        return  slist;
    }

/*
 * 查询全部车型
 *
 * @author Tigger Wu
 * @date 2018/8/16 13:15
 * @param
 * @return
 */

    public List<Vehicle> queryVice(){
        List<Vehicle> vehicles = vehicleMapper.selectAll();
        return  vehicles;
    }



}
